| API Documentation |  |

- MAIN PAGE
- NAMESPACES
- CLASSES

StructToString.h
1 // StructToString.h
3 //
5
6 namespace nkGraphics
7 {
13 class StructToString
14 {
15 public :
16
17 // Shader types
24 static nkMemory::StringView getShaderTypeString (SHADER_TYPE val) ;
31 static SHADER_TYPE getStringShaderType (nkMemory::StringView str) ;
32
33 // Shader semantics
40 static nkMemory::StringView getShaderSemanticString (SHADER_SEMANTIC val) ;
47 static SHADER_SEMANTIC getStringShaderSemantic (nkMemory::StringView str) ;
48
49 // Program profile
56 static nkMemory::StringView getProgramProfileString (PROGRAM_COMPILATION_PROFILE val) ;
63 static PROGRAM_COMPILATION_PROFILE getStringProgramProfile (nkMemory::StringView str) ;
64
65 // Blend
72 static nkMemory::StringView getBlendString (BLEND val) ;
79 static BLEND getStringBlend (nkMemory::StringView str) ;
86 static BLEND getBlendFromIndex (unsigned int index) ;
87
88 // Blend Op
95 static nkMemory::StringView getBlendOpString (BLEND_OP val) ;
102 static BLEND_OP getStringBlendOp (nkMemory::StringView str) ;
109 static BLEND_OP getBlendOpFromIndex (unsigned int index) ;
110
111 // Write mask
118 static nkMemory::StringView getWriteMaskString (COLOR_WRITE_ENABLE val) ;
125 static COLOR_WRITE_ENABLE getStringWriteMask (nkMemory::StringView str) ;
132 static COLOR_WRITE_ENABLE getWriteMaskFromIndex (unsigned int index) ;
133
134 // Depth write mask
141 static nkMemory::StringView getDepthWriteMaskString (DEPTH_WRITE_MASK val) ;
148 static DEPTH_WRITE_MASK getStringDepthWriteMask (nkMemory::StringView str) ;
155 static DEPTH_WRITE_MASK getDepthWriteMaskFromIndex (unsigned int index) ;
156
157 // Stencil op
164 static nkMemory::StringView getStencilOpString (STENCIL_OP val) ;
171 static STENCIL_OP getStringStencilOp (nkMemory::StringView str) ;
178 static STENCIL_OP getStencilOpFromIndex (unsigned int index) ;
179
180 // Fill mode
187 static nkMemory::StringView getFillModeString (FILL_MODE val) ;
194 static FILL_MODE getStringFillMode (nkMemory::StringView str) ;
201 static FILL_MODE getFillModeFromIndex (unsigned int index) ;
202
203 // Cull Mode
210 static nkMemory::StringView getCullModeString (CULL_MODE val) ;
217 static CULL_MODE getStringCullMode (nkMemory::StringView str) ;
224 static CULL_MODE getCullModeFromIndex (unsigned int index) ;
225
226 // Usage
233 static nkMemory::StringView getUsageString (BUFFER_USAGE val) ;
240 static BUFFER_USAGE getStringUsage (nkMemory::StringView str) ;
247 static BUFFER_USAGE getUsageFromIndex (unsigned int index) ;
248
249 // Format
256 static nkMemory::StringView getFormatString (FORMAT val) ;
263 static FORMAT getStringFormat (nkMemory::StringView str) ;
270 static FORMAT getFormatFromIndex (unsigned int index) ;
271
272 // Bind Flag
279 static nkMemory::StringView getBindFlagString (BUFFER_BIND_FLAG val) ;
286 static BUFFER_BIND_FLAG getStringBindFlag (nkMemory::StringView str) ;
293 static BUFFER_BIND_FLAG getBindFlagFromIndex (unsigned int index) ;
294
295 // CPU Access Flag
302 static nkMemory::StringView getCpuAccessFlagString (BUFFER_CPU_ACCESS_FLAG val) ;
309 static BUFFER_CPU_ACCESS_FLAG getStringCpuAccessFlag (nkMemory::StringView str) ;
316 static BUFFER_CPU_ACCESS_FLAG getCpuAccessFlagFromIndex (unsigned int index) ;
317
318 // Misc Flags
325 static nkMemory::StringView getMiscFlagString (RESOURCE_MISC_FLAG val) ;
332 static RESOURCE_MISC_FLAG getStringMiscFlag (nkMemory::StringView str) ;
339 static RESOURCE_MISC_FLAG getMiscFlagFromIndex (unsigned int index) ;
340
341 // Pass type
348 static nkMemory::StringView getPassTypeString (PASS_TYPE val) ;
355 static PASS_TYPE getStringPassType (nkMemory::StringView str) ;
356
357 // Resource type
364 static nkMemory::StringView getResourceTypeString (RESOURCE_TYPE val) ;
371 static RESOURCE_TYPE getStringResourceType (nkMemory::StringView str) ;
372
373 // Texture render flag
380 static nkMemory::StringView getTexRenderFlagString (TEXTURE_RENDER_FLAG val) ;
387 static TEXTURE_RENDER_FLAG getStringTexRenderFlag (nkMemory::StringView str) ;
388 } ;
389 }
nkGraphics::CULL_MODE
CULL_MODE
Available culling modes.
Definition: DxDefinesWrapper.h:308
nkGraphics::RESOURCE_MISC_FLAG
RESOURCE_MISC_FLAG
Available misc flags for resources.
Definition: ResourceMiscFlag.h:12
nkGraphics::BLEND_OP
BLEND_OP
Available blending operations.
Definition: DxDefinesWrapper.h:272
nkGraphics::StructToString::getFormatString
static nkMemory::StringView getFormatString(FORMAT val)
nkGraphics::StructToString::getCullModeString
static nkMemory::StringView getCullModeString(CULL_MODE val)
nkGraphics::StructToString::getDepthWriteMaskFromIndex
static DEPTH_WRITE_MASK getDepthWriteMaskFromIndex(unsigned int index)
nkGraphics::StructToString::getUsageFromIndex
static BUFFER_USAGE getUsageFromIndex(unsigned int index)
nkGraphics::RESOURCE_TYPE
RESOURCE_TYPE
The type of resources available in the component.
Definition: ResourceType.h:12
nkGraphics::BUFFER_CPU_ACCESS_FLAG
BUFFER_CPU_ACCESS_FLAG
Available cpu access flags.
Definition: BufferCpuAccessFlag.h:12
nkGraphics::SHADER_TYPE
SHADER_TYPE
Available shader types.
Definition: DxDefinesWrapper.h:319
nkGraphics::StructToString::getStringCpuAccessFlag
static BUFFER_CPU_ACCESS_FLAG getStringCpuAccessFlag(nkMemory::StringView str)
nkGraphics::StructToString::getPassTypeString
static nkMemory::StringView getPassTypeString(PASS_TYPE val)
nkGraphics::StructToString
Converts enums to string, and vice versa.
Definition: StructToString.h:14
nkGraphics::StructToString::getStencilOpFromIndex
static STENCIL_OP getStencilOpFromIndex(unsigned int index)
nkGraphics::StructToString::getShaderTypeString
static nkMemory::StringView getShaderTypeString(SHADER_TYPE val)
nkGraphics::StructToString::getBlendOpString
static nkMemory::StringView getBlendOpString(BLEND_OP val)
nkGraphics::StructToString::getCpuAccessFlagString
static nkMemory::StringView getCpuAccessFlagString(BUFFER_CPU_ACCESS_FLAG val)
nkGraphics::StructToString::getStringFillMode
static FILL_MODE getStringFillMode(nkMemory::StringView str)
nkGraphics::BUFFER_USAGE
BUFFER_USAGE
Available usage for buffers. Drives the memory used for hosting the data.
Definition: BufferUsage.h:12
nkGraphics::StructToString::getStringUsage
static BUFFER_USAGE getStringUsage(nkMemory::StringView str)
nkGraphics::StructToString::getResourceTypeString
static nkMemory::StringView getResourceTypeString(RESOURCE_TYPE val)
nkGraphics::StructToString::getStringShaderType
static SHADER_TYPE getStringShaderType(nkMemory::StringView str)
nkGraphics::StructToString::getBlendOpFromIndex
static BLEND_OP getBlendOpFromIndex(unsigned int index)
nkGraphics::StructToString::getBlendFromIndex
static BLEND getBlendFromIndex(unsigned int index)
nkGraphics::StructToString::getProgramProfileString
static nkMemory::StringView getProgramProfileString(PROGRAM_COMPILATION_PROFILE val)
nkGraphics::StructToString::getStringCullMode
static CULL_MODE getStringCullMode(nkMemory::StringView str)
nkGraphics::StructToString::getStringTexRenderFlag
static TEXTURE_RENDER_FLAG getStringTexRenderFlag(nkMemory::StringView str)
nkGraphics::StructToString::getFillModeFromIndex
static FILL_MODE getFillModeFromIndex(unsigned int index)
nkGraphics::StructToString::getCullModeFromIndex
static CULL_MODE getCullModeFromIndex(unsigned int index)
nkGraphics::StructToString::getStringResourceType
static RESOURCE_TYPE getStringResourceType(nkMemory::StringView str)
nkGraphics::DEPTH_WRITE_MASK
DEPTH_WRITE_MASK
Available depth write masks.
Definition: DxDefinesWrapper.h:124
nkGraphics::StructToString::getDepthWriteMaskString
static nkMemory::StringView getDepthWriteMaskString(DEPTH_WRITE_MASK val)
nkGraphics::StructToString::getStringWriteMask
static COLOR_WRITE_ENABLE getStringWriteMask(nkMemory::StringView str)
nkGraphics::StructToString::getStringFormat
static FORMAT getStringFormat(nkMemory::StringView str)
nkGraphics::StructToString::getWriteMaskFromIndex
static COLOR_WRITE_ENABLE getWriteMaskFromIndex(unsigned int index)
nkGraphics::StructToString::getStringBlendOp
static BLEND_OP getStringBlendOp(nkMemory::StringView str)
nkGraphics::StructToString::getStringStencilOp
static STENCIL_OP getStringStencilOp(nkMemory::StringView str)
nkGraphics::StructToString::getMiscFlagFromIndex
static RESOURCE_MISC_FLAG getMiscFlagFromIndex(unsigned int index)
nkGraphics::StructToString::getStringDepthWriteMask
static DEPTH_WRITE_MASK getStringDepthWriteMask(nkMemory::StringView str)
nkGraphics::StructToString::getBindFlagString
static nkMemory::StringView getBindFlagString(BUFFER_BIND_FLAG val)
nkGraphics::StructToString::getBlendString
static nkMemory::StringView getBlendString(BLEND val)
nkGraphics::COLOR_WRITE_ENABLE
COLOR_WRITE_ENABLE
Available color write masks.
Definition: DxDefinesWrapper.h:285
nkGraphics::BLEND
BLEND
Available blending types.
Definition: DxDefinesWrapper.h:247
nkGraphics::StructToString::getStencilOpString
static nkMemory::StringView getStencilOpString(STENCIL_OP val)
nkMemory::StringView
Class holding information about a string, with no ownership over the data.
Definition: StringView.h:22
nkGraphics::StructToString::getCpuAccessFlagFromIndex
static BUFFER_CPU_ACCESS_FLAG getCpuAccessFlagFromIndex(unsigned int index)
nkGraphics::StructToString::getMiscFlagString
static nkMemory::StringView getMiscFlagString(RESOURCE_MISC_FLAG val)
nkGraphics::PASS_TYPE
PASS_TYPE
The pass types available in the component.
Definition: PassType.h:12
nkGraphics::StructToString::getShaderSemanticString
static nkMemory::StringView getShaderSemanticString(SHADER_SEMANTIC val)
nkGraphics::StructToString::getStringPassType
static PASS_TYPE getStringPassType(nkMemory::StringView str)
nkGraphics::StructToString::getStringProgramProfile
static PROGRAM_COMPILATION_PROFILE getStringProgramProfile(nkMemory::StringView str)
nkGraphics::SHADER_SEMANTIC
SHADER_SEMANTIC
Available shader semantics.
Definition: DxDefinesWrapper.h:335
nkGraphics::StructToString::getStringBlend
static BLEND getStringBlend(nkMemory::StringView str)
nkGraphics::STENCIL_OP
STENCIL_OP
Available stencil operations.
Definition: DxDefinesWrapper.h:134
nkGraphics::StructToString::getStringBindFlag
static BUFFER_BIND_FLAG getStringBindFlag(nkMemory::StringView str)
nkGraphics::StructToString::getTexRenderFlagString
static nkMemory::StringView getTexRenderFlagString(TEXTURE_RENDER_FLAG val)
nkGraphics::FORMAT
FORMAT
Available formats for resources.
Definition: DxDefinesWrapper.h:13
nkGraphics::StructToString::getFormatFromIndex
static FORMAT getFormatFromIndex(unsigned int index)
nkGraphics::FILL_MODE
FILL_MODE
Available filling mode during rasterization.
Definition: DxDefinesWrapper.h:298
nkGraphics::StructToString::getBindFlagFromIndex
static BUFFER_BIND_FLAG getBindFlagFromIndex(unsigned int index)
nkGraphics::PROGRAM_COMPILATION_PROFILE
PROGRAM_COMPILATION_PROFILE
Available program compilation profiles.
Definition: ProgramCompilationProfile.h:14
nkGraphics
Encompasses all API of component NilkinsGraphics.
Definition: BoundingBox.h:7
nkGraphics::StructToString::getUsageString
static nkMemory::StringView getUsageString(BUFFER_USAGE val)
nkGraphics::StructToString::getStringMiscFlag
static RESOURCE_MISC_FLAG getStringMiscFlag(nkMemory::StringView str)
nkGraphics::StructToString::getFillModeString
static nkMemory::StringView getFillModeString(FILL_MODE val)
nkGraphics::StructToString::getWriteMaskString
static nkMemory::StringView getWriteMaskString(COLOR_WRITE_ENABLE val)
nkGraphics::BUFFER_BIND_FLAG
BUFFER_BIND_FLAG
Available binding flags for buffers.
Definition: BufferBindFlag.h:12
nkGraphics::StructToString::getStringShaderSemantic
static SHADER_SEMANTIC getStringShaderSemantic(nkMemory::StringView str)
nkGraphics::TEXTURE_RENDER_FLAG
TEXTURE_RENDER_FLAG
The render flag possible for a texture.
Definition: TextureRenderFlag.h:12